package com.it.demo.serviceImpl;

import com.it.demo.dao.PersonMapper;
import com.it.demo.pojo.Person;
import com.it.demo.service.PersonService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.Date;
import java.util.List;

@Service("personService")
public class PersonServiceImpl implements PersonService {
    @Resource
    private PersonMapper personMapper;
    @Override
    public List<Person> getAll() {
        System.out.println("调用personMapper");
        //String netherlands, Date currd
        return personMapper.getAll();
    }

    @Override
    public int add(Person person) {
        return personMapper.add(person);
    }

    @Override
    public int del(Integer id) {
        return personMapper.del(id);
    }

    @Override
    public int upd(Person person) {
        return personMapper.upd(person);
    }
}
